300
|
How can I change the font for entire item
with thisform.ComboBox1
.Columns.Add("Default")
.Items.AddItem("default font")
f = CreateObject("StdFont")
with f
.Name = "Tahoma"
.Size = 12
endwith
with .Items
.DefaultItem = .AddItem("new font")
.ItemFont(0) = f
endwith
endwith
|
299
|
How do I vertically align a cell

with thisform.ComboBox1
.DrawGridLines = -2
.Columns.Add("MultipleLine").Def(16) = .F.
.Columns.Add("VAlign")
with .Items
h = .AddItem("This is a bit of long text that should break the line")
.DefaultItem = h
.CellCaption(0,1) = "top"
.DefaultItem = h
.CellVAlignment(0,1) = 0
h = .AddItem("This is a bit of long text that should break the line")
.DefaultItem = h
.CellCaption(0,1) = "middle"
.DefaultItem = h
.CellVAlignment(0,1) = 1
h = .AddItem("This is a bit of long text that should break the line")
.DefaultItem = h
.CellCaption(0,1) = "bottom"
.DefaultItem = h
.CellVAlignment(0,1) = 2
endwith
endwith
|
298
|
How can I change the position of an item

with thisform.ComboBox1
.Columns.Add("Default")
with .Items
.AddItem("Item 1")
.AddItem("Item 2")
.DefaultItem = .AddItem("Item 3")
.ItemPosition(0) = 0
endwith
endwith
|
297
|
How do I find an item based on a path

with thisform.ComboBox1
.Columns.Add("Default")
with .Items
h = .AddItem("Root 1")
.InsertItem(h,Null,"Child 1")
.DefaultItem = .InsertItem(h,Null,"Child 2")
.ItemData(0) = 1234
.DefaultItem = h
.ExpandItem(0) = .T.
.DefaultItem = .FindPath("Root 1\Child 1")
.ItemBold(0) = .T.
endwith
endwith
|
296
|
How do I find an item

with thisform.ComboBox1
.Columns.Add("Default")
with .Items
h = .AddItem("Root 1")
.InsertItem(h,Null,"Child 1")
.InsertItem(h,Null,"Child 2")
.DefaultItem = h
.ExpandItem(0) = .T.
.DefaultItem = .FindItem("Child 2",0)
.ItemBold(0) = .T.
endwith
endwith
|
295
|
How can I insert a hyperlink or an anchor element

with thisform.ComboBox1
.Columns.Add("Column")
with .Items
.DefaultItem = .AddItem("Just an <a1>anchor</a> element ...")
.CellCaptionFormat(0,0) = 1
endwith
with .Items
.DefaultItem = .AddItem("Just another <a2>anchor</a> element ...")
.CellCaptionFormat(0,0) = 1
endwith
endwith
|
294
|
How do I find the index of the item based on its handle

with thisform.ComboBox1
.Columns.Add("Default")
with .Items
h = .AddItem("Root 1")
.InsertItem(h,Null,"Child 1")
.InsertItem(h,Null,"Child 2")
.DefaultItem = h
.ExpandItem(0) = .T.
.DefaultItem = .ItemByIndex(.ItemToIndex(h))
.ItemBold(0) = .T.
endwith
endwith
|
293
|
How do I find the handle of the item based on its index

with thisform.ComboBox1
.Columns.Add("Default")
with .Items
h = .AddItem("Root 1")
.InsertItem(h,Null,"Child 1")
.InsertItem(h,Null,"Child 2")
.DefaultItem = h
.ExpandItem(0) = .T.
.DefaultItem = .ItemByIndex(1)
.ItemBold(0) = .T.
endwith
endwith
|
292
|
How can I find the cell being clicked in a radio group

with thisform.ComboBox1
.MarkSearchColumn = .F.
.SelBackColor = RGB(255,255,128)
.SelForeColor = RGB(0,0,0)
.Columns.Add("C1")
.Columns.Add("C2")
.Columns.Add("C3")
with .Items
h = .AddItem("Cell 1")
.DefaultItem = h
.CellCaption(0,1) = "Radio 1"
.DefaultItem = h
.CellHasRadioButton(0,1) = .T.
.DefaultItem = h
.CellRadioGroup(0,1) = 1234
.DefaultItem = h
.CellCaption(0,2) = "Radio 2"
.DefaultItem = h
.CellHasRadioButton(0,2) = .T.
.DefaultItem = h
.CellRadioGroup(0,2) = 1234
.DefaultItem = h
.CellState(0,1) = 1
.CellBold(Null,.CellChecked(1234)) = .T.
endwith
endwith
|
291
|
Can I add a +/- ( expand / collapse ) buttons to each item, so I can load the child items later

with thisform.ComboBox1
.LinesAtRoot = -1
.Columns.Add("Default")
with .Items
.DefaultItem = .AddItem("parent item with no child items")
.ItemHasChildren(0) = .T.
.AddItem("next item")
endwith
endwith
|
290
|
Can I let the user to resize at runtime the specified item

with thisform.ComboBox1
.ScrollBySingleLine = .T.
.DrawGridLines = -2
.Columns.Add("Default")
with .Items
.DefaultItem = .AddItem("resizable item")
.ItemAllowSizing(0) = .T.
.AddItem("not resizable item")
endwith
endwith
|
289
|
How can I change the size ( width, height ) of the picture

with thisform.ComboBox1
.Columns.Add("Default")
with .Items
h = .AddItem("Root 1")
.DefaultItem = h
.CellPicture(0,0) = thisform.ComboBox1.ExecuteTemplate("loadpicture(`c:\exontrol\images\zipdisk.gif`)")
.DefaultItem = h
.CellPictureWidth(0,0) = 24
.DefaultItem = h
.CellPictureHeight(0,0) = 24
.DefaultItem = h
.ItemHeight(0) = 32
h = .AddItem("Root 2")
.DefaultItem = h
.CellPicture(0,0) = thisform.ComboBox1.ExecuteTemplate("loadpicture(`c:\exontrol\images\zipdisk.gif`)")
.DefaultItem = h
.ItemHeight(0) = 48
endwith
endwith
|
288
|
How do I unselect an item

with thisform.ComboBox1
.Columns.Add("Default")
with .Items
h = .AddItem("Root 1")
.InsertItem(h,Null,"Child 1")
.InsertItem(h,Null,"Child 2")
.DefaultItem = h
.ExpandItem(0) = .T.
.DefaultItem = h
.SelectItem(0) = .F.
endwith
endwith
|
287
|
How do I find the selected item

with thisform.ComboBox1
.Columns.Add("Default")
with .Items
h = .AddItem("Root 1")
.InsertItem(h,Null,"Child 1")
.InsertItem(h,Null,"Child 2")
.DefaultItem = h
.ExpandItem(0) = .T.
.DefaultItem = h
.SelectItem(0) = .T.
.DefaultItem = .SelectedItem(0)
.ItemBold(0) = .T.
endwith
endwith
|
286
|
How do I select an item

with thisform.ComboBox1
.Columns.Add("Default")
with .Items
h = .AddItem("Root 1")
.InsertItem(h,Null,"Child 1")
.InsertItem(h,Null,"Child 2")
.DefaultItem = h
.ExpandItem(0) = .T.
.DefaultItem = h
.SelectItem(0) = .T.
endwith
endwith
|
285
|
Can I display a button with some picture or icon inside

with thisform.ComboBox1
.Object.HTMLPicture("p1") = "c:\exontrol\images\zipdisk.gif"
.Columns.Add("C1")
.Columns.Add("C2")
with .Items
h = .AddItem("Cell 1")
.DefaultItem = h
.CellCaption(0,1) = " Button <img>p1</img> "
.DefaultItem = h
.CellCaptionFormat(0,1) = 1
.DefaultItem = h
.CellHAlignment(0,1) = 2
.DefaultItem = h
.CellHasButton(0,1) = .T.
.DefaultItem = h
.ItemHeight(0) = 48
endwith
endwith
|
284
|
Can I display a button with some picture or icon inside

with thisform.ComboBox1
var_s = "gBJJgBAIDAAGAAEAAQhYAf8Pf4hh0QihCJo2AEZjQAjEZFEaIEaEEaAIAkcbk0olUrlktl0vmExmUzmk1m03nE5nU7nk9n0/oFBoVDolFo1HpFJpVLplNp1PqFRqVTql"
var_s = var_s + "Vq1XrFZrVbrldr1fsFhsVjslls1ntFptVrtltt1vuFxuVzul1u13vF5vV7vl9v1/wGBwWDwmFw2HxGJxWLxmNx0xiFdyOTh8Tf9ZymXx+QytcyNgz8r0OblWjyWds+m0"
var_s = var_s + "ka1Vf1ta1+r1mos2xrG2xeZ0+a0W0qOx3GO4NV3WeyvD2XJ5XL5nN51aiw+lfSj0gkUkAEllHanHI5j/cHg8EZf7w8vl8j4f/qfEZeB09/vjLAB30+kZQAP/P5/H6/yN"
var_s = var_s + "AOAEAwCjMBwFAEDwJBMDwLBYAP2/8Hv8/gAGAD8LQs9w/nhDY/oygIA="
.Images(var_s)
.Columns.Add("C1")
.Columns.Add("C2")
with .Items
h = .AddItem("Cell 1")
.DefaultItem = h
.CellCaption(0,1) = " Button <img>1</img> "
.DefaultItem = h
.CellCaptionFormat(0,1) = 1
.DefaultItem = h
.CellHAlignment(0,1) = 2
.DefaultItem = h
.CellHasButton(0,1) = .T.
endwith
endwith
|
283
|
Can I display a button with some icon inside

with thisform.ComboBox1
var_s = "gBJJgBAIDAAGAAEAAQhYAf8Pf4hh0QihCJo2AEZjQAjEZFEaIEaEEaAIAkcbk0olUrlktl0vmExmUzmk1m03nE5nU7nk9n0/oFBoVDolFo1HpFJpVLplNp1PqFRqVTql"
var_s = var_s + "Vq1XrFZrVbrldr1fsFhsVjslls1ntFptVrtltt1vuFxuVzul1u13vF5vV7vl9v1/wGBwWDwmFw2HxGJxWLxmNx0xiFdyOTh8Tf9ZymXx+QytcyNgz8r0OblWjyWds+m0"
var_s = var_s + "ka1Vf1ta1+r1mos2xrG2xeZ0+a0W0qOx3GO4NV3WeyvD2XJ5XL5nN51aiw+lfSj0gkUkAEllHanHI5j/cHg8EZf7w8vl8j4f/qfEZeB09/vjLAB30+kZQAP/P5/H6/yN"
var_s = var_s + "AOAEAwCjMBwFAEDwJBMDwLBYAP2/8Hv8/gAGAD8LQs9w/nhDY/oygIA="
.Images(var_s)
.Columns.Add("C1")
.Columns.Add("C2")
with .Items
h = .AddItem("Cell 1")
.DefaultItem = h
.CellCaption(0,1) = " <img>1</img> "
.DefaultItem = h
.CellCaptionFormat(0,1) = 1
.DefaultItem = h
.CellHAlignment(0,1) = 2
.DefaultItem = h
.CellHasButton(0,1) = .T.
endwith
endwith
|
282
|
How can I assign multiple icon/picture to a cell

with thisform.ComboBox1
.Object.HTMLPicture("p1") = "c:\exontrol\images\zipdisk.gif"
.Object.HTMLPicture("p2") = "c:\exontrol\images\auction.gif"
.Columns.Add("Default")
with .Items
h = .AddItem("text <img>p1</img> another picture <img>p2</img> and so on")
.DefaultItem = h
.CellCaptionFormat(0,0) = 1
.DefaultItem = h
.CellPicture(0,0) = thisform.ComboBox1.ExecuteTemplate("loadpicture(`c:\exontrol\images\colorize.gif`)")
.DefaultItem = h
.ItemHeight(0) = 48
.AddItem("Root 2")
endwith
endwith
|
281
|
How can I assign an icon/picture to a cell

with thisform.ComboBox1
.Columns.Add("Default")
with .Items
h = .AddItem("Root 1")
.DefaultItem = h
.CellPicture(0,0) = thisform.ComboBox1.ExecuteTemplate("loadpicture(`c:\exontrol\images\zipdisk.gif`)")
.DefaultItem = h
.ItemHeight(0) = 48
.AddItem("Root 2")
endwith
endwith
|
280
|
How can I assign multiple icons/pictures to a cell

with thisform.ComboBox1
var_s = "gBJJgBAIDAAGAAEAAQhYAf8Pf4hh0QihCJo2AEZjQAjEZFEaIEaEEaAIAkcbk0olUrlktl0vmExmUzmk1m03nE5nU7nk9n0/oFBoVDolFo1HpFJpVLplNp1PqFRqVTql"
var_s = var_s + "Vq1XrFZrVbrldr1fsFhsVjslls1ntFptVrtltt1vuFxuVzul1u13vF5vV7vl9v1/wGBwWDwmFw2HxGJxWLxmNx0xiFdyOTh8Tf9ZymXx+QytcyNgz8r0OblWjyWds+m0"
var_s = var_s + "ka1Vf1ta1+r1mos2xrG2xeZ0+a0W0qOx3GO4NV3WeyvD2XJ5XL5nN51aiw+lfSj0gkUkAEllHanHI5j/cHg8EZf7w8vl8j4f/qfEZeB09/vjLAB30+kZQAP/P5/H6/yN"
var_s = var_s + "AOAEAwCjMBwFAEDwJBMDwLBYAP2/8Hv8/gAGAD8LQs9w/nhDY/oygIA="
.Images(var_s)
.Columns.Add("Default")
with .Items
h = .AddItem("Root <img>1</img> 1, <img>2</img>, ... and so on ")
.DefaultItem = h
.CellCaptionFormat(0,0) = 1
endwith
endwith
|
279
|
How can I assign multiple icons/pictures to a cell

with thisform.ComboBox1
var_s = "gBJJgBAIDAAGAAEAAQhYAf8Pf4hh0QihCJo2AEZjQAjEZFEaIEaEEaAIAkcbk0olUrlktl0vmExmUzmk1m03nE5nU7nk9n0/oFBoVDolFo1HpFJpVLplNp1PqFRqVTql"
var_s = var_s + "Vq1XrFZrVbrldr1fsFhsVjslls1ntFptVrtltt1vuFxuVzul1u13vF5vV7vl9v1/wGBwWDwmFw2HxGJxWLxmNx0xiFdyOTh8Tf9ZymXx+QytcyNgz8r0OblWjyWds+m0"
var_s = var_s + "ka1Vf1ta1+r1mos2xrG2xeZ0+a0W0qOx3GO4NV3WeyvD2XJ5XL5nN51aiw+lfSj0gkUkAEllHanHI5j/cHg8EZf7w8vl8j4f/qfEZeB09/vjLAB30+kZQAP/P5/H6/yN"
var_s = var_s + "AOAEAwCjMBwFAEDwJBMDwLBYAP2/8Hv8/gAGAD8LQs9w/nhDY/oygIA="
.Images(var_s)
.Columns.Add("Default")
with .Items
h = .AddItem("Root 1")
.DefaultItem = h
.CellImages(0,0) = "1,2,3"
endwith
endwith
|
278
|
How can I assign an icon/picture to a cell

with thisform.ComboBox1
var_s = "gBJJgBAIDAAGAAEAAQhYAf8Pf4hh0QihCJo2AEZjQAjEZFEaIEaEEaAIAkcbk0olUrlktl0vmExmUzmk1m03nE5nU7nk9n0/oFBoVDolFo1HpFJpVLplNp1PqFRqVTql"
var_s = var_s + "Vq1XrFZrVbrldr1fsFhsVjslls1ntFptVrtltt1vuFxuVzul1u13vF5vV7vl9v1/wGBwWDwmFw2HxGJxWLxmNx0xiFdyOTh8Tf9ZymXx+QytcyNgz8r0OblWjyWds+m0"
var_s = var_s + "ka1Vf1ta1+r1mos2xrG2xeZ0+a0W0qOx3GO4NV3WeyvD2XJ5XL5nN51aiw+lfSj0gkUkAEllHanHI5j/cHg8EZf7w8vl8j4f/qfEZeB09/vjLAB30+kZQAP/P5/H6/yN"
var_s = var_s + "AOAEAwCjMBwFAEDwJBMDwLBYAP2/8Hv8/gAGAD8LQs9w/nhDY/oygIA="
.Images(var_s)
.Columns.Add("Default")
with .Items
h = .AddItem("Root 1")
.DefaultItem = h
.CellImage(0,0) = 1
.DefaultItem = .InsertItem(h,Null,"Child 1")
.CellImage(0,0) = 2
.DefaultItem = .InsertItem(h,Null,"Child 2")
.CellImage(0,0) = 3
.DefaultItem = h
.ExpandItem(0) = .T.
endwith
endwith
|
277
|
How can I get the handle of an item based on the handle of the cell

with thisform.ComboBox1
.Columns.Add("Default")
with .Items
h = .AddItem("Root 1")
.InsertItem(h,Null,"Child 1")
.InsertItem(h,Null,"Child 2")
.DefaultItem = h
.ExpandItem(0) = .T.
.DefaultItem = .CellItem(.ItemCell(h,0))
.ItemBold(0) = .T.
endwith
endwith
|
276
|
How can I display a button inside the item or cell

with thisform.ComboBox1
.Columns.Add("C1")
.Columns.Add("C2")
with .Items
h = .AddItem("Cell 1")
.DefaultItem = h
.CellCaption(0,1) = " Button 1 "
.DefaultItem = h
.CellHAlignment(0,1) = 2
.DefaultItem = h
.CellHasButton(0,1) = .T.
h = .AddItem("Cell 2")
.DefaultItem = h
.CellCaption(0,1) = " Button 2 "
.DefaultItem = h
.CellHAlignment(0,1) = 1
.DefaultItem = h
.CellHasButton(0,1) = .T.
endwith
endwith
|
275
|
How can I change the state of a radio button

with thisform.ComboBox1
.MarkSearchColumn = .F.
.SelBackColor = RGB(255,255,128)
.SelForeColor = RGB(0,0,0)
.Columns.Add("C1")
.Columns.Add("C2")
.Columns.Add("C3")
with .Items
h = .AddItem("Cell 1")
.DefaultItem = h
.CellCaption(0,1) = "Radio 1"
.DefaultItem = h
.CellHasRadioButton(0,1) = .T.
.DefaultItem = h
.CellRadioGroup(0,1) = 1234
.DefaultItem = h
.CellCaption(0,2) = "Radio 2"
.DefaultItem = h
.CellHasRadioButton(0,2) = .T.
.DefaultItem = h
.CellRadioGroup(0,2) = 1234
.DefaultItem = h
.CellState(0,1) = 1
endwith
endwith
|
274
|
How can I assign a radio button to a cell

with thisform.ComboBox1
.MarkSearchColumn = .F.
.SelBackColor = RGB(255,255,128)
.SelForeColor = RGB(0,0,0)
.Columns.Add("C1")
.Columns.Add("C2")
.Columns.Add("C3")
with .Items
h = .AddItem("Cell 1")
.DefaultItem = h
.CellCaption(0,1) = "Radio 1"
.DefaultItem = h
.CellHasRadioButton(0,1) = .T.
.DefaultItem = h
.CellRadioGroup(0,1) = 1234
.DefaultItem = h
.CellCaption(0,2) = "Radio 2"
.DefaultItem = h
.CellHasRadioButton(0,2) = .T.
.DefaultItem = h
.CellRadioGroup(0,2) = 1234
.DefaultItem = h
.CellState(0,1) = 1
endwith
endwith
|
273
|
How can I change the state of a checkbox

with thisform.ComboBox1
.Columns.Add("C1")
.Columns.Add("C2")
with .Items
h = .AddItem("Cell 1")
.DefaultItem = h
.CellCaption(0,1) = "Check Box"
.DefaultItem = h
.CellHasCheckBox(0,1) = .T.
.DefaultItem = h
.CellState(0,1) = 1
endwith
endwith
|
272
|
How can I assign a checkbox to a cell

with thisform.ComboBox1
.Columns.Add("C1")
.Columns.Add("C2")
with .Items
h = .AddItem("Cell 1")
.DefaultItem = h
.CellCaption(0,1) = "Check Box"
.DefaultItem = h
.CellHasCheckBox(0,1) = .T.
endwith
endwith
|
271
|
How can I display an item or a cell on multiple lines

with thisform.ComboBox1
.ScrollBySingleLine = .T.
.Columns.Add("C1")
.Columns.Add("C2")
with .Items
h = .AddItem("Cell 1")
.DefaultItem = h
.CellCaption(0,1) = "This is bit of text that's shown on multiple lines"
.DefaultItem = h
.CellSingleLine(0,1) = .F.
endwith
endwith
|
270
|
How can I assign a tooltip to a cell

with thisform.ComboBox1
.Columns.Add("C1")
.Columns.Add("C2")
with .Items
h = .AddItem("Cell 1")
.DefaultItem = h
.CellCaption(0,1) = "tooltip"
.DefaultItem = h
.CellToolTip(0,1) = "This is bit of text that's shown when the user hovers the cell"
endwith
endwith
|
269
|
How can I associate an extra data to a cell

with thisform.ComboBox1
.Columns.Add("C1")
.Columns.Add("C2")
with .Items
h = .AddItem("Cell 1")
.DefaultItem = h
.CellCaption(0,1) = "Cell 2"
.DefaultItem = h
.CellData(0,1) = "your extra data"
endwith
endwith
|
268
|
How do I enable or disable a cell

with thisform.ComboBox1
.Columns.Add("C1")
.Columns.Add("C2")
with .Items
h = .AddItem("Cell 1")
.DefaultItem = h
.CellCaption(0,1) = "Cell 2"
.DefaultItem = h
.CellEnabled(0,1) = .F.
endwith
endwith
|
267
|
How do I change the cell's foreground color

with thisform.ComboBox1
.Columns.Add("C1")
.Columns.Add("C2")
with .Items
h = .AddItem("Cell 1")
.DefaultItem = h
.CellCaption(0,1) = "Cell 2"
.DefaultItem = h
.CellForeColor(0,1) = RGB(255,0,0)
endwith
endwith
|
266
|
How do I change the visual effect for the cell, using your EBN files

with thisform.ComboBox1
.VisualAppearance.Add(1,"c:\exontrol\images\normal.ebn")
.Columns.Add("C1")
.Columns.Add("C2")
with .Items
h = .AddItem("Cell 1")
.DefaultItem = h
.CellCaption(0,1) = "Cell 2"
.DefaultItem = h
.CellBackColor(0,1) = 0x1000000
endwith
endwith
|
265
|
How do I change the cell's background color

with thisform.ComboBox1
.Columns.Add("C1")
.Columns.Add("C2")
with .Items
h = .AddItem("Cell 1")
.DefaultItem = h
.CellCaption(0,1) = "Cell 2"
.DefaultItem = h
.CellBackColor(0,1) = RGB(255,0,0)
endwith
endwith
|
264
|
How do I change the caption or value for a particular cell

with thisform.ComboBox1
.Columns.Add("C1")
.Columns.Add("C2")
with .Items
.DefaultItem = .AddItem("Cell 1")
.CellCaption(0,1) = "Cell 2"
endwith
endwith
|
263
|
How do I get the handle of the cell

with thisform.ComboBox1
.Columns.Add("Default")
with .Items
h = .AddItem("Root 1")
.InsertItem(h,Null,"Child 1")
.InsertItem(h,Null,"Child 2")
.DefaultItem = h
.ExpandItem(0) = .T.
.CellBold(Null,.ItemCell(h,0)) = .T.
endwith
endwith
|
262
|
How do I retrieve the focused item

with thisform.ComboBox1
.Columns.Add("Default")
with .Items
h = .AddItem("Root 1")
.InsertItem(h,Null,"Child 1")
.InsertItem(h,Null,"Child 2")
.DefaultItem = h
.ExpandItem(0) = .T.
.DefaultItem = .FocusItem
.ItemBold(0) = .T.
endwith
endwith
|
261
|
How do I get the number or count of child items

with thisform.ComboBox1
.Columns.Add("Default")
with .Items
h = .AddItem("Root 1")
.InsertItem(h,Null,"Child 1")
.InsertItem(h,Null,"Child 2")
.DefaultItem = h
.ExpandItem(0) = .T.
.AddItem(.ChildCount(h))
endwith
endwith
|
260
|
How do I enumerate the visible items

with thisform.ComboBox1
.Columns.Add("Default")
with .Items
h = .AddItem("Root 1")
.InsertItem(h,Null,"Child 1")
.InsertItem(h,Null,"Child 2")
.DefaultItem = h
.ExpandItem(0) = .T.
h = .AddItem("Root 2")
.DefaultItem = .FirstVisibleItem
.ItemBold(0) = .T.
.DefaultItem = .NextVisibleItem(.FirstVisibleItem)
.ItemBold(0) = .T.
endwith
endwith
|
259
|
How do I enumerate the siblings items

with thisform.ComboBox1
.Columns.Add("Default")
with .Items
h = .AddItem("Root 1")
.InsertItem(h,Null,"Child 1")
.InsertItem(h,Null,"Child 2")
.DefaultItem = h
.ExpandItem(0) = .T.
h = .AddItem("Root 2")
.DefaultItem = .NextSiblingItem(.FirstVisibleItem)
.ItemBold(0) = .T.
.DefaultItem = .PrevSiblingItem(.NextSiblingItem(.FirstVisibleItem))
.ItemBold(0) = .T.
endwith
endwith
|
258
|
How do I get the parent item

with thisform.ComboBox1
.Columns.Add("Default")
with .Items
h = .AddItem("Root 1")
.InsertItem(h,Null,"Child 1")
.InsertItem(h,Null,"Child 2")
.DefaultItem = h
.ExpandItem(0) = .T.
.DefaultItem = .ItemParent(.ItemChild(h))
.ItemBold(0) = .T.
endwith
endwith
|
257
|
How do I get the first child item

with thisform.ComboBox1
.Columns.Add("Default")
with .Items
h = .AddItem("Root 1")
.InsertItem(h,Null,"Child 1")
.InsertItem(h,Null,"Child 2")
.DefaultItem = h
.ExpandItem(0) = .T.
.DefaultItem = .ItemChild(h)
.ItemBold(0) = .T.
endwith
endwith
|
256
|
How do I enumerate the root items

with thisform.ComboBox1
.Columns.Add("Default")
with .Items
h = .AddItem("Root 1")
.InsertItem(h,Null,"Child 1")
.InsertItem(h,Null,"Child 2")
.DefaultItem = h
.ExpandItem(0) = .T.
h = .AddItem("Root 2")
.InsertItem(h,Null,"Child 1")
.InsertItem(h,Null,"Child 2")
.DefaultItem = .RootItem(0)
.ItemBold(0) = .T.
.DefaultItem = .RootItem(1)
.ItemUnderline(0) = .T.
endwith
endwith
|
255
|
I have a hierarchy, how can I count the number of root items

with thisform.ComboBox1
.Columns.Add("Default")
with .Items
h = .AddItem("Root 1")
.InsertItem(h,Null,"Child 1")
.InsertItem(h,Null,"Child 2")
.DefaultItem = h
.ExpandItem(0) = .T.
h = .AddItem("Root 2")
.InsertItem(h,Null,"Child 1")
.InsertItem(h,Null,"Child 2")
.AddItem(.RootCount)
endwith
endwith
|
254
|
How can I make an item unselectable, or not selectable

with thisform.ComboBox1
.Columns.Add("Column")
with .Items
h = .AddItem("unselectable - you can't get selected")
.DefaultItem = h
.SelectableItem(0) = .F.
.AddItem("selectable")
endwith
endwith
|
253
|
How can I hide or show an item

with thisform.ComboBox1
.Columns.Add("Column")
with .Items
h = .AddItem("hidden")
.DefaultItem = h
.ItemHeight(0) = 0
.DefaultItem = h
.SelectableItem(0) = .F.
.AddItem("visible")
endwith
endwith
|
252
|
How can I change the height for all items

with thisform.ComboBox1
.DefaultItemHeight = 32
.Columns.Add("Column")
.Items.AddItem("One")
.Items.AddItem("Two")
endwith
|
251
|
How do I change the height of an item

with thisform.ComboBox1
.ScrollBySingleLine = .T.
.Columns.Add("Default")
with .Items
.DefaultItem = .AddItem("height")
.ItemHeight(0) = 128
endwith
.Items.AddItem("enabled")
endwith
|
250
|
How do I disable or enable an item

with thisform.ComboBox1
.Columns.Add("Default")
with .Items
.DefaultItem = .AddItem("disabled")
.EnableItem(0) = .F.
endwith
.Items.AddItem("enabled")
endwith
|
249
|
How do I display as strikeout a cell

with thisform.ComboBox1
.Columns.Add("Default")
with .Items
.DefaultItem = .AddItem("strikeout")
.CellStrikeOut(0,0) = .T.
endwith
endwith
|
248
|
How do I display as strikeout a cell or an item

with thisform.ComboBox1
.Columns.Add("Default")
with .Items
.DefaultItem = .AddItem("gets <s>strikeout</s> only a portion of text")
.CellCaptionFormat(0,0) = 1
endwith
endwith
|
247
|
How do I display as strikeout an item

with thisform.ComboBox1
.Columns.Add("Default")
with .Items
.DefaultItem = .AddItem("strikeout")
.ItemStrikeOut(0) = .T.
endwith
endwith
|
246
|
How do I underline a cell

with thisform.ComboBox1
.Columns.Add("Default")
with .Items
.DefaultItem = .AddItem("underline")
.CellUnderline(0,0) = .T.
endwith
endwith
|
245
|
How do I underline a cell or an item

with thisform.ComboBox1
.Columns.Add("Default")
with .Items
.DefaultItem = .AddItem("gets <u>underline</u> only a portion of text")
.CellCaptionFormat(0,0) = 1
endwith
endwith
|
244
|
How do I underline an item

with thisform.ComboBox1
.Columns.Add("Default")
with .Items
.DefaultItem = .AddItem("underline")
.ItemUnderline(0) = .T.
endwith
endwith
|
243
|
How do I display as italic a cell

with thisform.ComboBox1
.Columns.Add("Default")
with .Items
.DefaultItem = .AddItem("italic")
.CellItalic(0,0) = .T.
endwith
endwith
|
242
|
How do I display as italic a cell or an item

with thisform.ComboBox1
.Columns.Add("Default")
with .Items
.DefaultItem = .AddItem("gets <i>italic</i> only a portion of text")
.CellCaptionFormat(0,0) = 1
endwith
endwith
|
241
|
How do I display as italic an item

with thisform.ComboBox1
.Columns.Add("Default")
with .Items
.DefaultItem = .AddItem("italic")
.ItemItalic(0) = .T.
endwith
endwith
|
240
|
How do I bold a cell

with thisform.ComboBox1
.Columns.Add("Default")
with .Items
.DefaultItem = .AddItem("bold")
.CellBold(0,0) = .T.
endwith
endwith
|
239
|
How do I bold a cell or an item

with thisform.ComboBox1
.Columns.Add("Default")
with .Items
.DefaultItem = .AddItem("gets <b>bold</b> only a portion of text")
.CellCaptionFormat(0,0) = 1
endwith
endwith
|
238
|
How do I bold an item

with thisform.ComboBox1
.Columns.Add("Default")
with .Items
.DefaultItem = .AddItem("bold")
.ItemBold(0) = .T.
endwith
endwith
|
237
|
How do I change the foreground color for the item

with thisform.ComboBox1
.Columns.Add("Default")
with .Items
h = .AddItem("Root")
hC = .InsertItem(h,Null,"Child 1")
.DefaultItem = hC
.ItemForeColor(0) = RGB(255,0,0)
.InsertItem(h,Null,"Child 2")
.DefaultItem = h
.ExpandItem(0) = .T.
endwith
endwith
|
236
|
How do I change the visual appearance for the item, using your EBN technology

with thisform.ComboBox1
.VisualAppearance.Add(1,"c:\exontrol\images\normal.ebn")
.Columns.Add("Default")
with .Items
h = .AddItem("Root")
hC = .InsertItem(h,Null,"Child 1")
.DefaultItem = hC
.ItemBackColor(0) = 0x1000000
.InsertItem(h,Null,"Child 2")
.DefaultItem = h
.ExpandItem(0) = .T.
endwith
endwith
|
235
|
How do I change the background color for the item

with thisform.ComboBox1
.Columns.Add("Default")
with .Items
h = .AddItem("Root")
hC = .InsertItem(h,Null,"Child 1")
.DefaultItem = hC
.ItemBackColor(0) = RGB(255,0,0)
.InsertItem(h,Null,"Child 2")
.DefaultItem = h
.ExpandItem(0) = .T.
endwith
endwith
|
234
|
How do I expand or collapse an item

with thisform.ComboBox1
.Columns.Add("Default")
with .Items
h = .AddItem("Root")
.InsertItem(h,Null,"Child 1")
.InsertItem(h,Null,"Child 2")
.DefaultItem = h
.ExpandItem(0) = .T.
endwith
endwith
|
233
|
How do I associate an extra data to an item

with thisform.ComboBox1
.Columns.Add("Default")
with .Items
.DefaultItem = .AddItem("item")
.ItemData(0) = "your extra data"
endwith
endwith
|
232
|
How do I get the number or count of items

with thisform.ComboBox1
.Columns.Add("Default")
with .Items
h = .AddItem("Root")
.InsertItem(h,Null,"Child 1")
.InsertItem(h,Null,"Child 2")
.DefaultItem = h
.ExpandItem(0) = .T.
endwith
with .Items
.AddItem(.ItemCount)
endwith
endwith
|
231
|
How can I change at runtime the parent of the item

with thisform.ComboBox1
.LinesAtRoot = -1
.Columns.Add("Default")
with .Items
hP = .AddItem("Root")
hC = .AddItem("Child")
.SetParent(hC,hP)
endwith
endwith
|
230
|
How can I sort the items

with thisform.ComboBox1
.Columns.Add("Default")
with .Items
h = .AddItem("Root")
.InsertItem(h,Null,"Child 1")
.InsertItem(h,Null,"Child 2")
.DefaultItem = h
.ExpandItem(0) = .T.
endwith
.Columns.Item("Default").SortOrder = 2
endwith
|
229
|
How do I sort the child items

with thisform.ComboBox1
.Columns.Add("Default")
with .Items
h = .AddItem("Root")
.InsertItem(h,Null,"Child 1")
.InsertItem(h,Null,"Child 2")
.DefaultItem = h
.ExpandItem(0) = .T.
.SortChildren(h,0,.F.)
endwith
endwith
|
228
|
How can I remove or delete all items

with thisform.ComboBox1
.Columns.Add("Default")
.Items.AddItem("removed item")
.Items.RemoveAllItems
endwith
|
227
|
How can I remove or delete an item

with thisform.ComboBox1
.Columns.Add("Default")
h = .Items.AddItem("removed item")
.Items.RemoveItem(h)
endwith
|
226
|
How can I add or insert child items

with thisform.ComboBox1
.LinesAtRoot = -1
.Columns.Add("C1")
.Columns.Add("C2")
with .Items
h = .AddItem("Cell 1")
.DefaultItem = h
.CellCaption(0,1) = "Cell 2"
.DefaultItem = .InsertItem(h,Null,"Cell 3")
.CellCaption(0,1) = "Cell 4"
.DefaultItem = .InsertItem(h,Null,"Cell 5")
.CellCaption(0,1) = "Cell 6"
.DefaultItem = h
.ExpandItem(0) = .T.
endwith
endwith
|
225
|
How can I add or insert a child item

with thisform.ComboBox1
.LinesAtRoot = -1
.Columns.Add("Default")
with .Items
.InsertItem(.AddItem("root"),Null,"child")
endwith
endwith
|
224
|
How can I add or insert an item

with thisform.ComboBox1
.Columns.Add("C1")
.Columns.Add("C2")
with .Items
.DefaultItem = .AddItem("Cell 1")
.CellCaption(0,1) = "Cell 2"
h = .AddItem("Cell 3")
.DefaultItem = h
.CellCaption(0,1) = "Cell 4"
endwith
endwith
|
223
|
How can I add or insert an item

with thisform.ComboBox1
.Columns.Add("Default")
.Items.AddItem("new item")
endwith
|
222
|
How can I get the columns as they are shown in the control's sortbar
with thisform.ComboBox1
var_Object = .Columns.ItemBySortPosition(0)
endwith
|
221
|
How can I access the properties of a column

with thisform.ComboBox1
.Columns.Add("A")
.Columns.Item("A").HeaderBold = .T.
endwith
|
220
|
How can I remove all the columns

with thisform.ComboBox1
.Columns.Clear
endwith
|
219
|
How can I remove a column

with thisform.ComboBox1
.Columns.Remove("A")
endwith
|
218
|
How can I get the number or the count of columns
with thisform.ComboBox1
var_Count = .Columns.Count
endwith
|
217
|
How can I change the font for all cells in the entire column

with thisform.ComboBox1
f = CreateObject("StdFont")
with f
.Name = "Tahoma"
.Size = 12
endwith
with .ConditionalFormats.Add("1")
.Font = f
.ApplyTo = 0
endwith
.Columns.Add("Column")
.Items.AddItem(0)
.Items.AddItem(1)
endwith
|
216
|
How can I change the background color for all cells in the column

with thisform.ComboBox1
var_ConditionalFormat = .ConditionalFormats.Add("1")
with var_ConditionalFormat
.BackColor = RGB(255,0,0)
.ApplyTo = 0
endwith
.Columns.Add("Column")
.Items.AddItem(0)
.Items.AddItem(1)
endwith
|
215
|
How can I change the foreground color for all cells in the column

with thisform.ComboBox1
var_ConditionalFormat = .ConditionalFormats.Add("1")
with var_ConditionalFormat
.ForeColor = RGB(255,0,0)
.ApplyTo = 0
endwith
.Columns.Add("Column")
.Items.AddItem(0)
.Items.AddItem(1)
endwith
|
214
|
How can I show as strikeout all cells in the column

with thisform.ComboBox1
var_ConditionalFormat = .ConditionalFormats.Add("1")
with var_ConditionalFormat
.StrikeOut = .T.
.ApplyTo = 0
endwith
.Columns.Add("Column")
.Items.AddItem(0)
.Items.AddItem(1)
endwith
|
213
|
How can I underline all cells in the column

with thisform.ComboBox1
var_ConditionalFormat = .ConditionalFormats.Add("1")
with var_ConditionalFormat
.Underline = .T.
.ApplyTo = 0
endwith
.Columns.Add("Column")
.Items.AddItem(0)
.Items.AddItem(1)
endwith
|
212
|
How can I show in italic all data in the column

with thisform.ComboBox1
var_ConditionalFormat = .ConditionalFormats.Add("1")
with var_ConditionalFormat
.Italic = .T.
.ApplyTo = 0
endwith
.Columns.Add("Column")
.Items.AddItem(0)
.Items.AddItem(1)
endwith
|
211
|
How can I bold the entire column

with thisform.ComboBox1
var_ConditionalFormat = .ConditionalFormats.Add("1")
with var_ConditionalFormat
.Bold = .T.
.ApplyTo = 0
endwith
.Columns.Add("Column")
.Items.AddItem(0)
.Items.AddItem(1)
endwith
|
210
|
How can I display a computed column and highlight some values that are negative or less than a value

with thisform.ComboBox1
.Columns.Add("A")
.Columns.Add("B")
.Columns.Add("(A+B)*1.19").ComputedField = "(%0 + %1) * 1.19"
with .Items
.DefaultItem = .AddItem(1)
.CellCaption(0,1) = 2
endwith
with .Items
.DefaultItem = .AddItem(10)
.CellCaption(0,1) = 20
endwith
var_ConditionalFormat = .ConditionalFormats.Add("%2 > 10")
with var_ConditionalFormat
.Bold = .T.
.ForeColor = RGB(255,0,0)
.ApplyTo = 2 && 0x2
endwith
endwith
|
209
|
Can I display a computed column so it displays the VAT, or SUM

with thisform.ComboBox1
.Columns.Add("A")
.Columns.Add("B")
.Columns.Add("(A+B)*1.19").ComputedField = "(%0 + %1) * 1.19"
with .Items
.DefaultItem = .AddItem(1)
.CellCaption(0,1) = 2
endwith
with .Items
.DefaultItem = .AddItem(10)
.CellCaption(0,1) = 20
endwith
endwith
|
208
|
How can I show a column that adds values in the cells

with thisform.ComboBox1
.Columns.Add("A")
.Columns.Add("B")
.Columns.Add("A+B").ComputedField = "%0 + %1"
with .Items
.DefaultItem = .AddItem(1)
.CellCaption(0,1) = 2
endwith
with .Items
.DefaultItem = .AddItem(10)
.CellCaption(0,1) = 20
endwith
endwith
|
207
|
Is there any function to filter the control's data as I type, so the items being displayed include the typed characters

with thisform.ComboBox1
var_Column = .Columns.Add("Filter")
with var_Column
.FilterOnType = .T.
.DisplayFilterButton = .T.
.AutoSearch = 1
endwith
.Items.AddItem("Canada")
.Items.AddItem("USA")
endwith
|
206
|
Is there any function to filter the control's data as I type, something like filter on type

with thisform.ComboBox1
var_Column = .Columns.Add("Filter")
with var_Column
.FilterOnType = .T.
.DisplayFilterButton = .T.
endwith
.Items.AddItem("Canada")
.Items.AddItem("USA")
endwith
|
205
|
How can I programmatically filter a column

with thisform.ComboBox1
with .Columns.Add("Filter")
.DisplayFilterButton = .T.
.FilterType = 2
endwith
.Items.AddItem()
.Items.AddItem("not empty")
.ApplyFilter
endwith
|
204
|
How can I show or display the control's filter

with thisform.ComboBox1
.Columns.Add("Filter").DisplayFilterButton = .T.
endwith
|
203
|
How can I customize the items being displayed in the drop down filter window

with thisform.ComboBox1
with .Columns.Add("Custom Filter")
.DisplayFilterButton = .T.
.DisplayFilterPattern = .F.
var_s = "Excel Spreadsheets (*.xls )||*.xls|||Word Documents||*.doc|||Powerpoint Presentations||*.pps|||Text Documents (*.log,*.txt)||*.t"
var_s = var_s + "xt|*.log"
.CustomFilter = var_s
.FilterType = 3
.Filter = "*.xls"
endwith
.Items.AddItem("excel.xls")
.Items.AddItem("word.doc")
.Items.AddItem("pp.pps")
.Items.AddItem("text.txt")
.ApplyFilter
endwith
|
202
|
How can I change the order or the position of the columns in the sort bar

with thisform.ComboBox1
.SortBarVisible = .T.
.SortBarColumnWidth = 48
.Columns.Add("C1").SortOrder = 1
.Columns.Add("C2").SortOrder = 2
.Columns.Item("C2").SortPosition = 0
endwith
|
201
|
How do I arrange my columns on multiple levels

with thisform.ComboBox1
.Columns.Add("S").Width = 32
.Columns.Add("Level 2").LevelKey = 1
.Columns.Add("Level 3").LevelKey = 1
.Columns.Add("Level 4").LevelKey = 1
.Columns.Add("Level 1").LevelKey = "2"
.Columns.Add("Level 2").LevelKey = "2"
.Columns.Add("Level 3").LevelKey = "2"
.Columns.Add("Level 4").LevelKey = "2"
.Columns.Add("E").Width = 32
endwith
|